home *** CD-ROM | disk | FTP | other *** search
- Path: news2.ios.com!usenet
- From: vlad@gramercy.ios.com (Vlastimil Adamovsky)
- Newsgroups: comp.lang.c++,comp.lang.smalltalk
- Subject: Re: Considering Switch from Smalltalk to C++
- Date: Fri, 26 Jan 1996 14:05:59 GMT
- Organization: Internet Online Services
- Message-ID: <4eamnf$q16@news2.ios.com>
- References: <4e349d$3ol@bigjohn.bmi.net>
- NNTP-Posting-Host: ppp-37.ts-7.hck.idt.net
- X-Newsreader: Forte Free Agent 1.0.82
-
- Frank Skorina <skorina@bmi.net> wrote:
-
- >This post is to solicit opinions on our situation, especially from people who have
- >developed applications similar to our own. We would be interested in information
- >from those who have made the switch.
-
- It can be both easy and difficult:
-
- a) if you have clearly separeted your application code from the GUI
-
- code, then you should not get any problems. It means, your
- application should not know anything about the the implementation
- of the GUI.
- Your code should not call aCheckButton->check().
- It is better to call:
- MySeparationLayer.buttonAt("myCheckButton")->check().
- etc....
-
- b) If you use class as a first class object, then you need some
- redesign:
- *) in Smalltalk you write:
-
- ^MyStuff defaultClass new
-
- and you will get an instance (for example) of class Printer
- if the implementation of the method "defaultClass" is:
-
- defaultClass
- ^Printer
-
- Try to do it in C++
-
- c) In Smalltalk you can send messages to a variable that references
- some object of uknown class.
-
- In C++ you must define at least some superclass to be able to call
-
- member functions.
-
- d) etc....
-
- Though it is not impossible to "port" Smalltalk code to C++ code.
-
- The above mentioned things prove that design is language dependent
- despite of commonly accepted believe.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- *******************************************
- * Vlastimil Adamovsky *
- * Smalltalk, C++ and Envelop development *
- *******************************************
-
-